1. Field of the Invention
The present invention relates generally to displaying graphics on an electronic display screen and, more particularly, to preparing graphics for display on an electronic display screen on a computer system or portable electronic device.
2. Description of the Related Art
This section is intended to introduce the reader to various aspects of art that may be related to various aspects of the present invention, which are described and/or claimed below. This discussion is believed to be helpful in providing the reader with background information to facilitate a better understanding of the various aspects of the present invention. Accordingly, it should be understood that these statements are to be read in this light, and not as admissions of prior art.
A display screen for an electronic device often displays a new frame of pixels each time the screen refreshes. Each successive frame of pixels may be stored in a portion of memory known as a framebuffer, which holds data corresponding to each pixel of the frame. A display controller generally transfers pixel data from the framebuffer to special pre-display memory registers before the pixels appear on the screen.
A framebuffer often includes a series of scanlines, each of which corresponds to a row of pixels. The electronic device generally accesses pixel data from a scanline in read bursts. Thus, depending on the number of pixels displayed on each row of the screen, the particular pixel encoding used, and the length of each read burst, each scanline may need to be accessed numerous times per screen refresh.
Additionally or alternatively, multiple layers of frames of pixels may be accumulated into a single layer for display. Each layer may employ a unique framebuffer containing pixel data encoded in a red, green, blue, alpha (RGBA) color space, providing both color information and a level of transparency for each pixel. In certain applications, such as video playback, a topmost layer may contain a small number of visible pixels for displaying video status and a large number of transparent pixels, while a layer beneath the topmost layer may contain the video for playback. The topmost layer may remain largely unchanged from one frame to the next, and most scanlines of the framebuffer holding each frame may contain exclusively transparent pixels. However, the electronic device may still access each scanline numerous times to obtain the same pixels. During each scanline access, the device consumes a small amount of processing resources, memory resources, and power.
As the demand for smaller portable electronic devices with wide ranges of functionality increases, processing and memory resources, as well as power efficiency, may become increasingly valuable. For applications such as the playback of a movie, the amount of system resources consumed by repeatedly accessing a scanline of a framebuffer may be substantial. Moreover, though certain techniques, such as run length encoding, may mitigate some excess data transfer, such techniques may unnecessarily require additional processing and/or may not operate as efficiently as desired.